package StudyCode.summary.mycollection;

import java.util.Collections;
import java.util.HashSet;

/**
 * 版权所有 科技与人文(www.tah1986.com)
 */
public class FindMaximumElementOfHashSet {
	public static void main(String[] args) {
		HashSet hashSet = new HashSet();

		hashSet.add(new Long("9"));
		hashSet.add(new Long("4"));
		hashSet.add(new Long("2"));
		hashSet.add(new Long("2"));
		hashSet.add(new Long("3"));
		Object obj = Collections.max(hashSet);

		System.out.println("HashSet 最大的元素是 : " + obj);
	}
}
